package cn.echoedu.dao;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;

import cn.echoedu.daoconstants.TableName;
import cn.echoedu.entity.SchoolCalendar;
import cn.echoedu.entity.TelContacts;

public interface DAORead {
	public abstract <T> List<T> getAll(Connection con,TableName tableName)throws
	SQLException;
	public abstract <T> List<T> getPojoForLeftJoinAndColumn(Connection con,TableName lefttablename,
			TableName righttablename,String leftcolumn,String rightcolumn, 
			String column, String value,String sortbysql) 
					throws SQLException;
	public abstract <T> List<T> getAllForInput(Connection con,TableName tableName,
			String columnName,String searchValue) throws SQLException;
	public abstract <T> T getPojoForPrimarKey(Connection con,TableName tableName,
			String primaryKey) throws SQLException;
	public abstract <T> boolean alreadyExisting(Connection con,TableName tableName,
			String primaryKey) throws SQLException;
	public abstract <T> boolean alreadyExisting(Connection con,TableName tableName,
			T currentPojo) throws SQLException;
	public abstract <T> List<T> getPojoForSql(Connection con,TableName tablename,String sql)
			throws SQLException;
	public abstract int getCount(Connection connection,
			TableName schoolNotifyTable);
	public abstract int getMaxId(Connection connection,
			TableName tablename, String primary, String column,
			String value, String addstr);
	 public abstract int getMiniId(Connection connection,
			TableName classNotifyTable, String string, String string2,
			String string3, String object);
	public abstract <T> List<T> getContactsList(Connection connection,
			TableName telContactsTable, int schoolcode, String search_key);
	
}
